package com.bdmc.smokesensor.dao;
 
import com.bdmc.smokesensor.entity.*;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

import java.io.Serializable;
import java.util.List;
 
public interface Rbac_FunctionJPA extends JpaRepository<Rbac_Function,Integer>,JpaSpecificationExecutor<Rbac_Function>,Serializable {
  public List<Rbac_Function> findByparentFunIdOrderByFunOrderAsc(int pid);

  @Query(value="select f.* from rbac_function f where FIND_IN_SET(f.id,:ids) ",nativeQuery=true)
  public List<Rbac_Function> getFunctionByString(String ids);

  
}
